package com.szxy.miaosha.service;

import com.szxy.miaosha.domain.MiaoshaUser;
import com.szxy.miaosha.domain.OrderInfo;
import com.szxy.miaosha.exception.GlobalException;
import com.szxy.miaosha.vo.LoginVo;
import org.springframework.ui.Model;

import javax.servlet.http.HttpServletResponse;

/**
 * @Author:zwer
 * @Date:2020/9/6 21:58
 * @Description:com.szxy.miaosha.service
 * @Version:1.0
 **/
public interface MiaoShaUserService {

    /**
     * 登录
     *
     * @param loginVo
     * @param resp
     * @return
     */
    String login(LoginVo loginVo, HttpServletResponse resp) throws GlobalException;

    /**
     * 从 Reids 中根据 token ，获取用户信息
     *
     * @param resp
     * @param token
     * @return
     */
    MiaoshaUser getByToken(HttpServletResponse resp, String token);

}
